{% extends "ProjetCoursBundle::layout.html.twig" %}

{% block title %}
	Accueil - {{ parent() }}
{% endblock %}

{% block Enseignement_body %}

<h1>Document</h1>

<table class="table">
    <tbody>
        <tr>
            <th>Nom</th>
            <td>{{ entity.nom }}</td>
        </tr>
        <tr>
            <th>Description</th>
            <td>{{ entity.description }}</td>
        </tr>  
        <tr>
            <th>Created_at</th>
            <td>{{ entity.createdat|date('Y-m-d H:i:s') }}</td>
        </tr>
        <tr>
            <th>Télécharger</th>
            <td><a href="../../../{{ entity.getWebPath }}/{{ entity.nom }}"> {{ entity.nom }} </a></td>
        </tr>
    </tbody>
</table>

<ul class="record_actions">
    <li>
        <a href="{{ path('document') }}">
            Back to the list
        </a>
    </li>
    <li>
        <a href="{{ path('document_edit', { 'id': entity.id }) }}">
            Edit
        </a>
    </li>
    <li>
        <form action="{{ path('document_delete', { 'id': entity.id }) }}" method="post">
            {{ form_widget(delete_form) }}
            <button type="submit">Delete</button>
        </form>
    </li>
</ul>
{% endblock %}